<?php
/**
 * Default Pages Manager Template
 *
 * @package OWL
 * @subpackage Default Template
 * @author KeiMOon
 * @since 1.0
 */
class Template_Pages_Manager extends Owl_Master_Template {
    protected function init() {
        $user = Owl_User::get_instance();
        if (!$user->is_logged_in()) {
            Owl_Functions::go_to_template("login");
        }
        assign("title", get_option("site_name") . " - " . __("Pages manager"));
        assign("page-title", __("Pages manager"));
        enqueue_style('default-setting,default-icon,default-ajax,default-jtable');
        enqueue_script('default-pages-manager');
        $this->owl_page = new Owl_Page();
    }

    protected function main_content() {
?>
<div id="setting-navigation">
    <?php Owl_Default_Content::setting_navigation(); ?>
    <div style="clear:both;"></div>
</div>
<div id="setting-page-header" class="has-icon icon-pages-manager-48">
    <div id="setting-page-title">
        <?php put("page-title"); ?>
    </div>
</div>
<div id="setting-main-content">
    <h3><?php echo __("Pages list"); ?></h3>
    <div id="pages-manager">
        <table class="jtable" id="pages-table" border="0" cellpadding="0" cellspacing="0">
            <thead>
                <tr>
                    <th width="50%">
                        <?php echo __("Page's title"); ?>
                    </th>
                    <th>
                        <?php echo __("Create date"); ?>
                    </th>
                    <th>
                        <?php echo __("Modify date"); ?>
                    </th>
                </tr>
            </thead>
            <tfoot>
                <tr>
                    <td colspan="3">
                        <span  class="pages-pagination"></span>
                        <img src=" <?php Owl_Link::image_url(); ?>default/ajax-load.gif" class="ajax-load" alt="Ajax load" />
                    </td>
                </tr>
            </tfoot>
            <tbody>
            </tbody>
        </table>
        <?php Owl_Default_Content::print_ajax_feedback(false); ?>
    </div>
</div>

<?php
    }
}